/* */
package com.zhiwei.msf.common.config;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.Ordered;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

import com.zhiwei.msf.common.interceptor.SecurityInterceptor;

/**
 * @function:
 * @author zhiwei.yang
 * @time 2022年7月8日-下午7:05:59
 */
@Configuration
public class WebConfig implements WebMvcConfigurer {

	@Autowired
	private SecurityInterceptor securityInterceptor;

	@Override
	public void addInterceptors(InterceptorRegistry registry) {
		registry.addInterceptor(securityInterceptor).order(Ordered.LOWEST_PRECEDENCE);
	}
}
